package com.ydkj.a37e_mall.Classes.Model.Request;

import android.util.Log;

import com.ydkj.a37e_mall.Classes.Model.Base.BaseReq;
import com.ydkj.a37e_mall.Resource.Utils.Rsa;

/**
 * Created by hong on 2017/2/23.
 */
public class GetMallOrderListReq extends BaseReq {

    //uuid=用户uuid(登录接口返回的uuid)&store_id=当要获取某个门店下的订单时，需要发送非必需参数门店编号，通过api/store/store_list接口获取
    // &delivery_type=订单类型(1为配送上门,2为门店自提)&stats=订单状态id(通过api/store/stats获取)&page=当前页&page_size=每页显示数量的RSA加密字符串

    private String uuid;
    private String delivery_type;
    private String stats;
    private String page;
    private String page_size;
    private String secret;

    public String getUuid() {
        return uuid;
    }

    public void setUuid(String uuid) {
        this.uuid = uuid;
    }


    public String getDelivery_type() {
        return delivery_type;
    }

    public void setDelivery_type(String delivery_type) {
        this.delivery_type = delivery_type;
    }

    public String getStats() {
        return stats;
    }

    public void setStats(String stats) {
        this.stats = stats;
    }

    public String getPage() {
        return page;
    }

    public void setPage(String page) {
        this.page = page;
    }

    public String getPage_size() {
        return page_size;
    }

    public void setPage_size(String page_size) {
        this.page_size = page_size;
    }

    public String urlString() {
        return "order/order";
    }

    public String getSecret() {
        String string = "uuid=" + uuid + "&delivery_type=" + delivery_type + "&stats=" + stats + "&page=" + page + "&page_size=" + page_size;

        try {
            Rsa rsa = new Rsa();
            secret = rsa.encryptByPublic(string);
        } catch (Exception e) {
            e.printStackTrace();
        }
        Log.e("ssss", "我的订单source===>" + string);
        return secret;
    }
}
